-- GENERATED SPELL FOR [Wildspawn Felsworn] --


function spell0_11455(pUnit, Event) --@Chaotic Focus,n/a--
pUnit:FullCastSpellOnTarget(22418,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11455', 0, 1)
end

function spell1_11455(pUnit, Event) --@Fear,n/a--
pUnit:FullCastSpellOnTarget(12542,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11455', 5500, 1)
end

function spell2_11455(pUnit, Event) --@Shadow Bolt,n/a--
pUnit:FullCastSpellOnTarget(15537,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11455', 3000, 1)
end

function spell3_11455(pUnit, Event) --@Shadow Shield,n/a--
pUnit:FullCastSpellOnTarget(22417,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11455', 30326, 1)
end

function spell4_11455(pUnit, Event) --@Shadow Word: Pain,n/a--
pUnit:FullCastSpellOnTarget(15654,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11455', 18000, 1)
end

function Sorts_11455(pUnit, Event)
local choix_sorts_11455 = math.random(0, 4)
if choix_sorts_11455 == 0 then
pUnit:RegisterEvent('spell0_11455', 1, 1)
end
if choix_sorts_11455 == 1 then
pUnit:RegisterEvent('spell1_11455', 1, 1)
end
if choix_sorts_11455 == 2 then
pUnit:RegisterEvent('spell2_11455', 1, 1)
end
if choix_sorts_11455 == 3 then
pUnit:RegisterEvent('spell3_11455', 1, 1)
end
if choix_sorts_11455 == 4 then
pUnit:RegisterEvent('spell4_11455', 1, 1)
end
end

function mob11455_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_11455', math.random(1500, 3000), 1)
end

function mob11455_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob11455_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob11455_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(11455, 1, 'mob11455_Action')
RegisterUnitEvent(11455, 2, 'mob11455_Leave')
RegisterUnitEvent(11455, 3, 'mob11455_Kill')
RegisterUnitEvent(11455, 4, 'mob11455_Die')
